/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Reeks5.VanRansbeeck.Kevin.Model.States.Game;

import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author climacon
 */
public class ShowdownState implements PokerSpelState {
    
    public String getStatus() {
        return "Showdown time!";
    }

    public void flop(SpelStateContext aThis) {
        try {
            throw new IllegalGameActionException("Pre-flop gaat enkel vanuit new state.");
        } catch (IllegalGameActionException ex) {
            Logger.getLogger(ShowdownState.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    public void turn(SpelStateContext aThis) {
        try {
            throw new IllegalGameActionException("Turn kan alleen vanuit flop state.");
        } catch (IllegalGameActionException ex) {
            Logger.getLogger(ShowdownState.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    public void river(SpelStateContext aThis) {
        try {
            throw new IllegalGameActionException("River gaat alleen vanuit turn.");
        } catch (IllegalGameActionException ex) {
            Logger.getLogger(ShowdownState.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    public void showdown(SpelStateContext aThis) {
        try {
            throw new IllegalGameActionException("Dit IS de showdown.");
        } catch (IllegalGameActionException ex) {
            Logger.getLogger(ShowdownState.class.getName()).log(Level.SEVERE, null, ex);
        }
    }
    
    public void blinds(SpelStateContext aThis) {
        try {
            throw new IllegalGameActionException("Pre-flop gaat enkel vanuit new state.");
        } catch (IllegalGameActionException ex) {
            Logger.getLogger(ShowdownState.class.getName()).log(Level.SEVERE, null, ex);
        }
    }
    
    public void winner(SpelStateContext aThis) {
        aThis.setSpelState(new WinnerState());
    }

    public void reset(SpelStateContext aThis) {
        try {
            throw new IllegalGameActionException("Reset kan alleen vanuit winnaar state komen.");
        } catch (IllegalGameActionException ex) {
            Logger.getLogger(ShowdownState.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

}
